package com.finalcial.service.impl;

import java.util.Date;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.finalcial.dao.ReadDao;
import com.finalcial.service.ReadService;
/**
 * 我的待阅以及已阅页面
 * @author Lenovo
 *
 */
@Service
public class ReadServiceImpl implements ReadService {
	
	@Autowired
	private ReadDao readDao; 

	/**
	 * 进入已阅待阅界面
	 */
	@Override
	public List<Map<String, Object>> listReadMsg(Integer userId,String workStateName, Integer startPos,Integer pageSize){
		return readDao.listReadMsg(userId, workStateName, startPos, pageSize);
	}
	/**
	 * 已阅待阅搜索--多条件查询
	 */
	@Override
	public List<Map<String, Object>> getReadMsg(Integer userId, String workStateName, String userName,
			String startTime, String endTime) {
		return readDao.getReadMsg(userId, workStateName, userName, startTime, endTime);
	}
	/**
	 * 点击具体某一行数据进入补单查询页面
	 * @param reimbursementId 报销id
	 * @return 补单原因 说明 时间 补单张数  金额
	 */
	@Override
	public List<Map<String, Object>> getSingleSupplement(String reimbursementId) {
		return readDao.getSingleSupplement(reimbursementId);
	}
	/**
	 * 统计已阅待阅总条数
	 */
	@Override
	public Integer listReadMsgCounts(Integer userId, String workStateName) {
		return readDao.listReadMsgCounts(userId, workStateName);
	}
	
	

}
